home *** CD-ROM | disk | FTP | other *** search
/ Scene Storm / Scene Storm - Volume 1.iso / coding / c / vbcc / machines / amiga68k / doc / vc.doc < prev    next >
Encoding:
Text File  |  1995-11-23  |  5.0 KB  |  138 lines

  1. vc - frontend for Amiga version of vbcc (c) in 1995 by Volker Barthelmann
  2.  
  3.  
  4. INTRODUCTION
  5.  
  6.     vc calls the preprocessor, compiler, assembler and linker.
  7.     It should be somewhat Unix cc compatible.
  8.  
  9.  
  10. LEGAL
  11.  
  12.     vc is (c) in 1995 by Volker Barthelmann. All code is written by me
  13.     and may be freely redistributed as long as no modifications are made
  14.     and nothing is charged for it.
  15.  
  16.  
  17. INSTALLATION
  18.  
  19.     This may change in following versions.
  20.  
  21.     First set Your stack not too low. I have not tested how much stack
  22.     vbcc needs, some 10k will probably be enough.
  23.  
  24.     At the moment vc calls an external preprocessor, so this one must be
  25.     in the path and You probably have to make an assign to tell the
  26.     preprocessor the directories that contain the vbcc includes (and the os
  27.     includes, if You have them) - this depends on the preprocessor You
  28.     chose.
  29.     E.g. if You use dcpp from the FreeDice-archive on aminet, You have to
  30.  
  31.     assign dinclude: machines/amiga68k/include [Your os-include-dir]
  32.  
  33.     Also You have to edit the -pp and -ppv options in the config file
  34.     to call the preprocessor (see below) if You do not use dcpp.
  35.     In the future vbcc will probably have a builtin preprocessor.
  36.  
  37.     vbcc, FreePhxAss and Your linker must also be in the path and vlib: must
  38.     be assigned to vbcc's lib directory (vbcc/machines/amiga68k/lib).
  39.  
  40.     Also You should assign vbcc: to a directory and/or put a config file
  41.     (see CONFIG) in vbcc: or env:. If You do neither of this, You will get
  42.     an annoying requester even if You use the default config of vc.
  43.  
  44.     In the default configuration, vc will call dcpp as preprocessor,
  45.     FreePhxAss as assembler and blink as linker. You can change this
  46.     with the following command line options (which can be put in a config
  47.     file).
  48.  
  49.     -pp=string  The preprocessor will be called like in
  50.                 printf(string,infile,outfile), e.g. the default for dcpp
  51.                 would be "-pp=dcpp %s >%s"
  52.  
  53.     -as=string  The same for the assembler. The default would be
  54.                 "-as=FreePhxAss opt ! quiet %s to %s".
  55.                 You probably don't have to change this.
  56.  
  57.     -rm=string  This is the string for the delete command and takes only
  58.                 one argument. The default would be "-rm=delete quiet %s".
  59.                 You probably don't have to change this.
  60.  
  61.     -ld=string  This is for the linker and takes three arguments. The first
  62.                 one are the object files (separated by spaces), the second
  63.                 one the user specified libraries and the last one the name
  64.                 of the resulting executable.
  65.                 This command has to link with vlib:startup.o as first object
  66.                 file and vlib:vc.lib and vlib:amiga.lib as the last libraries.
  67.                 The appropriate (and default) line for blink/slink would be
  68.                 "-ld=blink vlib:startup.o %s lib %s vlib:vc.lib vlib:amiga.lib
  69.                  to %s"
  70.                 For PhxLnk You could use
  71.                 "-ld=PhxLnk vlib:startup.o %s %s vlib:vc.lib vlib:amiga.lib
  72.                  to %s"
  73.  
  74.     All those strings should tell the command to omit any output apart from
  75.     error messages if possible. However for every of those options there
  76.     exists one with an additional 'v', i.e. -ppv=, -asv=, etc. which should
  77.     produce some output, if possible.
  78.     If vc is invoked with the -vv option the verbose commands will be called,
  79.     if not the quiet ones will be used.
  80.  
  81.  
  82. CONFIG
  83.  
  84.     vc looks for a config file named 'vc.config' in ENV: and VBCC:. If
  85.     it is found it will be treated as a collection of additional command
  86.     line arguments. Every line of the file will be used as one argument,
  87.     so no quoting shall be used and every argument must go in its own
  88.     line.
  89.     There should be an example vc.config.
  90.  
  91.  
  92. USAGE
  93.  
  94.     vc [options] file1 file2 ...
  95.  
  96.     Processes all files according to their suffix and links all objects
  97.     together (unless any of -E, -S, -c is specified). It recognizes the
  98.     following file types:
  99.  
  100.     .c      C source
  101.     .i      already preprocessed C source
  102.     .asm
  103.     .s      assembler source
  104.     .obj
  105.     .o      object file
  106.  
  107.     With dos.library >=36 pattern matching is supported.
  108.  
  109.     The options recognized by vc are:
  110.  
  111.     -v      verbose; print all commands
  112.  
  113.     -vv     very verbose; display some internals, too
  114.  
  115.     -Ox     optimization level; at the moment -O0 means -O=0 and -O2 means
  116.             -O=1023; default is -O=1
  117.  
  118.     -o file save executable as file (default a.out); only works if the
  119.             target is an executable
  120.  
  121.     -E      do not compile, save the preprocessed C sources with .i suffix
  122.  
  123.     -S      do not assemble, save the compiled files with .asm suffix
  124.  
  125.     -c      do not link, .o suffix
  126.  
  127.     -k      keep all intermediate files; by default all generated files
  128.             except the source files and the targets are deleted
  129.  
  130.     -lulib  link with library vlib:ulib.lib
  131.  
  132.  
  133.     All other options are passed through to vbcc.
  134.  
  135.  
  136. Volker                                                  volker@vb.franken.de
  137.  
  138.